import request from '@/utils/request'
import { websock } from '@/websock'

// 员工列表
export function userList(params) {
  return websock.userList(params)
}

// 添加员工
export function addUser(params) {
  return websock.addUser(params)
}

// 修改员工密码
export function modifyUserPwd(data) {
  return request({
    url: '/admin/modifyUserPwd',
    method: 'post',
    data
  })
}

// 删除员工
export function delUser(data) {
  return request({
    url: '/admin/delUser',
    method: 'post',
    data
  })
}

// 从部门岗位中移除
export function rmUserFromDp(data) {
  return request({
    url: '/admin/rmFromDp',
    method: 'post',
    data
  })
}

// 部门岗位调整
export function updateUserDp(data) {
  return request({
    url: '/admin/updateUserDp',
    method: 'post',
    data
  })
}

// 添加部门岗位
export function addUserDp(data) {
  return request({
    url: '/admin/addUserDp',
    method: 'post',
    data
  })
}

// 更新员工信息
export function updateUserInfo(data) {
  return request({
    url: '/admin/updateUserInfo',
    method: 'post',
    data
  })
}

export function hourRechargeList(params) {
  return request({
    url: '/player/hourRechargeList',
    method: 'get',
    params
  })
}

export function hourRechargeDay(params) {
  return request({
    url: '/player/hourRechargeDay',
    method: 'get',
    params
  })
}

export function monthRechargeList() {
  return request({
    url: '/player/monthRechargeList',
    method: 'get'
  })
}

// 玩家列表
export function employee(params) {
  return request({
    url: '/player/list',
    method: 'get',
    params
  })
}
